//
//  AlertBoot.swift
//  SwiftUIWidgetDemo
//
//  Created by alanzhangg on 2023/7/15.
//

import SwiftUI

struct AlertBoot: View {
    
    @State var showAlert: Bool = false
    
    var body: some View {
        Button("Click Here") {
            showAlert.toggle()
        }
        .alert("alert", isPresented: $showAlert) {
            Button("hello 🤒", role: .destructive) {
                
            }
            Button("cancel", role: .cancel) {
                
            }
            
        }
    }
}

#Preview {
    AlertBoot()
}
